
allpos = [(40, 100),
             (60, 100),
             (80, 100),
             (100, 100),
             (60, 60),
             (60, 80),
             (480, 400),
             (480, 380),
             (520, 400),
             (560, 400),
             (60, 120),
             (60, 140),
             (60, 160),
             (80, 160),
             (100, 160),
             (220, 80),
             (220, 60),
             (200, 40),
             (180, 40),
             (160, 60),
             (160, 60),
             (160, 80),
             (160, 100),
             (160, 140),
             (160, 140),
             (180, 180),
             (200, 180),
             (220, 160),
             (220, 140),
             (280, 40),
             (280, 40),
             (300, 40),
             (320, 40),
             (340, 40),
             (300, 60),
             (300, 80),
             (300, 100),
             (300, 120),
             (300, 140),
             (300, 160),
             (440, 40),
             (420, 40),
             (380, 40),
             (380, 40),
             (380, 60),
             (380, 80),
             (380, 100),
             (380, 120),
             (380, 140),
             (380, 160),
             (400, 100),
             (420, 100),
             (560, 20),
             (540, 20),
             (540, 40),
             (540, 60),
             (540, 80),
             (540, 100),
             (540, 120),
             (540, 160),
             (560, 160),
             (100, 240),
             (80, 240),
             (60, 240),
             (40, 260),
             (40, 280),
             (60, 300),
             (80, 320),
             (100, 340),
             (100, 380),
             (60, 400),
             (80, 400),
             (40, 380),
             (40, 340),
             (160, 320),
             (160, 340),
             (160, 360),
             (160, 380),
             (180, 320),
             (200, 300),
             (220, 320),
             (220, 340),
             (220, 360),
             (220, 380),
             (260, 320),
             (280, 320),
             (280, 300),
             (320, 300),
             (320, 320),
             (320, 340),
             (320, 360),
             (320, 380),
             (300, 380),
             (280, 380),
             (260, 360),
             (280, 340),
             (300, 340),
             (380, 240),
             (380, 280),
             (380, 300),
             (380, 340),
             (380, 360),
             (380, 380),
             (420, 320),
             (440, 300),
             (420, 360),
             (440, 380),
             (560, 260),
             (520, 260),
             (480, 260),
             (480, 280),
             (480, 320),
             (520, 320),
             (560, 320),
             (40, 480),
             (40, 500),
             (40, 540),
             (80, 540),
             (80, 480),
             (100, 480),
             (100, 540),
             (40, 560),
             (40, 580),
             (40, 600),
             (160, 520),
             (160, 560),
             (160, 580),
             (160, 600),
             (200, 600),
             (220, 520),
             (220, 560),
             (220, 580),
             (220, 600),
             (260, 520),
             (260, 540),
             (260, 580),
             (260, 600),
             (280, 540),
             (300, 520),
             (320, 520),
             (340, 540),
             (340, 560),
             (340, 580),
             (340, 600),
             (380, 480),
             (380, 500),
             (380, 540),
             (380, 560),
             (380, 600),
             (400, 520),
             (420, 560),
             (440, 600),
             (440, 560),
             (440, 540),
             (440, 500),
             (440, 480),
             (480, 520),
             (500, 560),
             (520, 580),
             (560, 520),
             (540, 560),
             (520, 600),
             (520, 620),
             (480, 620),
             (600, 440),
             (620, 480),
             (620, 520),
             (620, 520),
             (620, 540),
             (620, 580),
             (620, 600),
             (600, 600)]

import matplotlib.pyplot as plt
from matplotlib.patches import Rectangle

#define Matplotlib figure and axis
fig, ax = plt.subplots()

#create simple line plot
ax.plot([0, 750],[0,750])

#add rectangle to plot

for i in allpos:

    ax.add_patch(Rectangle((i[0], i[1]), 20, 20))

#display plot
plt.show()


